package com.vastcom.sigma.admin.dao;

import com.vastcom.sigma.admin.model.Encapsort;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;

import java.util.List;

public interface EncapsortDao extends JpaRepository<Encapsort,String> {

    /*@Query("select c from Cargocate c where c.pid=:cargocateid order by c.basecode")
    List<Cargocate> getCargocatesByCargocateid(@Param("cargocateid") String cargocateid);*/

    @Query("select e from Encapsort e where e.clqk =:clqk order by e.fjsj desc ")
    List<Encapsort> getEncapsortsByClqk(@Param("clqk") String clqk);

    @Query("select e from Encapsort e order by e.fjsj desc ")
    List<Encapsort> getEncapsortsByFjsj();
}
